package com.gxl.design.decoratorpattern.decoretor;

import com.gxl.design.decoratorpattern.Animal;

public class DecoratorAnimalImpl extends DecoratorAnimal {

    public DecoratorAnimalImpl(Animal animal) {
        super(animal);
    }

    @Override
    public void animalName() {
        this.animal.animalName();
        this.red();
    }

    public void red() {
        System.out.print("涂上红色");
    }
}
